﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Server.aspx.cs" Inherits="WinnerCMS.WebUI.Admin.Soft.Server" %>

<%@ Register Src="../UC_AjaxLoading.ascx" TagName="UC_AjaxLoading" TagPrefix="uc1" %>
<!doctype html>
<html>
<head runat="server">
    <title>镜像服务器</title>
    <meta charset="utf-8" />
    <meta http-equiv="Pragma" content="No-cach" />
    <%: Styles.Render("~/Content/Bootstrap/css") %>
    <%: Scripts.Render("~/Scripts/AdminBase") %>
</head>
<body>
    <form id="form1" runat="server">
    <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <asp:UpdateProgress ID="UpdateProgress1" runat="server">
        <ProgressTemplate>
            <uc1:UC_AjaxLoading ID="UC_AjaxLoading1" runat="server" />
        </ProgressTemplate>
    </asp:UpdateProgress>
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
            <table cellspacing="0" cellpadding="0" width="100%" border="0">
                <tr>
                    <td style="width: 92px" height="30" align="right">&nbsp;&nbsp; 管理导航：
                    </td>
                    <td height="30" align="left">&nbsp;
                                    <asp:LinkButton ID="LinkButton1" runat="server" EnableViewState="False" OnClick="LinkButton1_Click">镜像服务器管理</asp:LinkButton>&nbsp;
                                    |&nbsp;
                                    <asp:LinkButton ID="LinkButton2" runat="server" EnableViewState="False" OnClick="LinkButton2_Click">添加镜像服务器</asp:LinkButton>
                    </td>
                </tr>
                <tr>
                    <td align="right" height="30" style="width: 92px">说明：
                    </td>
                    <td align="left" height="30">&nbsp;如果您的网站需要添加别人网站的软件链接，请保留至少一个空下载地址、没有<span style="color: #ff6666"><strong>下级服务器</strong></span>的<strong><span
                        style="color: #ff6666">服务器组</span></strong>
                    </td>
                </tr>
            </table>
            <table id="NavigationPath">
                <tr>
                    <td width="50%">
                        &nbsp;
                        <asp:Label ID="lblPath" runat="server" EnableViewState="False"></asp:Label>
                    </td>
                    <td width="50%">
                    </td>
                </tr>
            </table>
            <asp:Panel ID="Panel1" runat="server" Height="50px" Width="100%">
                <asp:GridView ID="GV_List" runat="server" AutoGenerateColumns="False" DataKeyNames="ID"
                    GridLines="None" CssClass="table table-bordered table-condensed table-hover" OnRowCommand="GV_List_RowCommand" OnRowDataBound="GV_List_RowDataBound">
                    <HeaderStyle CssClass="HeaderStyle" />
                    <Columns>
                        <asp:TemplateField HeaderText="选择">
                            <ItemStyle Width="30px" HorizontalAlign="Center" />
                            <ItemTemplate>
                                <asp:CheckBox ID="cbkSelectID" runat="server" />
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:BoundField DataField="ID" HeaderText="ID">
                            <ItemStyle Width="40px" HorizontalAlign="Center" />
                            <HeaderStyle Width="40px" />
                        </asp:BoundField>
                        <asp:TemplateField HeaderText="服务器代号">
                            <ItemTemplate>
                                <asp:Label ID="Label1" runat="server" Text='<%# Chang(Eval("ServerName"), Eval("ParentId")) %>'></asp:Label>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:BoundField DataField="ServerHTML" HeaderText="下载名称" />
                        <asp:BoundField DataField="DownURL" HeaderText="下载地址预写"></asp:BoundField>
                        <asp:BoundField DataField="LinkProperty" HeaderText="链接属性" Visible="false">
                            <ItemStyle Width="60px" HorizontalAlign="Center" />
                        </asp:BoundField>
                        <asp:ButtonField HeaderText="锁定" Text="锁定" CommandName="IsLock" DataTextField="IsLock">
                            <ItemStyle HorizontalAlign="Center" Width="40px" />
                        </asp:ButtonField>
                        <asp:ButtonField HeaderText="修改" Text="修改" CommandName="EditSoftServer">
                            <ItemStyle HorizontalAlign="Center" Width="40px" />
                        </asp:ButtonField>
                        <asp:ButtonField HeaderText="删除" Text="删除" CommandName="DelSoftServer">
                            <ItemStyle HorizontalAlign="Center" Width="40px" />
                        </asp:ButtonField>
                    </Columns>
                </asp:GridView>
                <br />
            </asp:Panel>
            <br />
            <asp:Panel ID="Panel2" runat="server" Width="100%" HorizontalAlign="Center">
                <table cellspacing="0" cellpadding="0" width="700" border="0">
                    <tr>
                        <td class="HeaderStyle" align="center" width="100%">
                            添加镜像服务器
                        </td>
                    </tr>
                    <tr>
                        <td class="border" colspan="3" height="30">
                            <table cellspacing="0" cellpadding="0" width="100%" border="0">
                                <tr>
                                    <td style="width: 141px; height: 30px;" align="right">
                                        所属：&nbsp;
                                    </td>
                                    <td align="left" style="height: 30px">
                                        <asp:DropDownList ID="ddlServerGroup" runat="server" ValidationGroup="AddOrEdit">
                                        </asp:DropDownList>
                                        <span style="color: #ff0033">*</span>
                                    </td>
                                </tr>
                                <tr>
                                    <td align="right" height="30" style="width: 141px">
                                        服务器代号：
                                    </td>
                                    <td align="left" height="30">
                                        <asp:TextBox ID="txtServerName" runat="server" ValidationGroup="AddOrEdit"></asp:TextBox>
                                        <span style="color: #ff0033">*</span>
                                        <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txtServerName"
                                            ErrorMessage="请输入" ValidationGroup="AddOrEdit"></asp:RequiredFieldValidator>
                                    </td>
                                </tr>
                                <tr>
                                    <td align="right" height="30" style="width: 141px">
                                        下载名称：
                                    </td>
                                    <td align="left" height="30">
                                        <asp:TextBox ID="txtServerHTML" runat="server" ValidationGroup="AddOrEdit"></asp:TextBox>
                                        支持HTML、JS
                                    </td>
                                </tr>
                                <tr>
                                    <td align="right" height="30" style="width: 141px">
                                        预设下载地址：
                                    </td>
                                    <td align="left" height="30">
                                        <asp:TextBox ID="txtDownURL" runat="server" Width="325px" ValidationGroup="AddOrEdit"></asp:TextBox>
                                        支持HTML、JS
                                    </td>
                                </tr>
                                <tr>
                                    <td colspan="2" height="30">
                                        <asp:Button ID="btnOK" runat="server" Text="确定" EnableViewState="False" OnClick="btnOK_Click"
                                            ValidationGroup="AddOrEdit" Cssclass="btn btn-default" />
                                    </td>
                                </tr>
                            </table>
                        </td>
                    </tr>
                </table>
            </asp:Panel>
        </ContentTemplate>
    </asp:UpdatePanel>
    </form>
</body>
</html>
